// condition.js
Page({
  data: {
    conditionList: [
      { id: 1, name: '条件一', checked: false },
      { id: 2, name: '条件二', checked: false },
      { id: 3, name: '条件三', checked: false }
    ]
  },
  
  onLoad() {
    console.log('condition页面加载')
  },
  
  // 切换条件状态
  toggleCondition(e) {
    const index = e.currentTarget.dataset.index
    const conditionList = this.data.conditionList
    conditionList[index].checked = !conditionList[index].checked
    this.setData({
      conditionList: conditionList
    })
  },
  
  // 跳转到列表页
  goToList() {
    wx.navigateTo({
      url: '/pages/list/list'
    })
  }
})
